package 进阶.IO.属性集;

import java.util.Properties;
import java.util.Set;

public class demo01 {
    public static void main(String[] args) {
        show();

    }

    private static void show() {
        Properties p = new Properties();

        //底层调用map的方法，索引存储键值对
        p.setProperty("jack","19");
        p.setProperty("rose","90");
        p.setProperty("peter","100");

        Set<String> set = p.stringPropertyNames();

        for(String key: set){
            String value = p.getProperty(key);
            System.out.println("key" + value);
        }

    }
}
